package com.gakj.truck.third.core.enums;

public enum EnumTruckPublishStatus {

	NEVERAUDIT("0", "未审核"), WAITAUDIT("1", "审核中"), HASAUDIT("2", "已审核") ,HASSALE("3","已售") ,NOAUDIT("4", "审核未通过"), NOTSALE("5", "下架");

	private String code;
    private String name;

	private EnumTruckPublishStatus(String code, String name) {
		this.code = code;
		this.name = name;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public static EnumTruckPublishStatus getEnum(String value) {
		for (EnumTruckPublishStatus e : EnumTruckPublishStatus.values()) {
			if (value.equals(e.getCode())) {
				return e;
			}
		}
		return null;
	}
}
